package com.his.bean;

import java.io.Serializable;

/**
 * 用户免费提问额度
 * @TableName dzm_his_patient_credit
 */
public class DzmHisPatientCredit implements Serializable {
    /**
     * 
     */
    private Integer id;

    /**
     * 医院id
     */
    private Integer hospitalId;

    /**
     * 患者id
     */
    private Integer patientId;

    /**
     * 医生id,若为0，就是通用类型
     */
    private Integer doctorId;

    /**
     * 来源id，用户提问id
     */
    private Integer qaId;

    /**
     * 使用状态：0，未使用，1已使用
     */
    private Boolean status;

    /**
     * 使用于哪个问题id
     */
    private Integer qaId2;

    /**
     * 添加时间
     */
    private Integer addtime;

    /**
     * 更新时间
     */
    private Integer uptime;

    private static final long serialVersionUID = 1L;

    /**
     * 
     */
    public Integer getId() {
        return id;
    }

    /**
     * 
     */
    public void setId(Integer id) {
        this.id = id;
    }

    /**
     * 医院id
     */
    public Integer getHospitalId() {
        return hospitalId;
    }

    /**
     * 医院id
     */
    public void setHospitalId(Integer hospitalId) {
        this.hospitalId = hospitalId;
    }

    /**
     * 患者id
     */
    public Integer getPatientId() {
        return patientId;
    }

    /**
     * 患者id
     */
    public void setPatientId(Integer patientId) {
        this.patientId = patientId;
    }

    /**
     * 医生id,若为0，就是通用类型
     */
    public Integer getDoctorId() {
        return doctorId;
    }

    /**
     * 医生id,若为0，就是通用类型
     */
    public void setDoctorId(Integer doctorId) {
        this.doctorId = doctorId;
    }

    /**
     * 来源id，用户提问id
     */
    public Integer getQaId() {
        return qaId;
    }

    /**
     * 来源id，用户提问id
     */
    public void setQaId(Integer qaId) {
        this.qaId = qaId;
    }

    /**
     * 使用状态：0，未使用，1已使用
     */
    public Boolean getStatus() {
        return status;
    }

    /**
     * 使用状态：0，未使用，1已使用
     */
    public void setStatus(Boolean status) {
        this.status = status;
    }

    /**
     * 使用于哪个问题id
     */
    public Integer getQaId2() {
        return qaId2;
    }

    /**
     * 使用于哪个问题id
     */
    public void setQaId2(Integer qaId2) {
        this.qaId2 = qaId2;
    }

    /**
     * 添加时间
     */
    public Integer getAddtime() {
        return addtime;
    }

    /**
     * 添加时间
     */
    public void setAddtime(Integer addtime) {
        this.addtime = addtime;
    }

    /**
     * 更新时间
     */
    public Integer getUptime() {
        return uptime;
    }

    /**
     * 更新时间
     */
    public void setUptime(Integer uptime) {
        this.uptime = uptime;
    }

    @Override
    public boolean equals(Object that) {
        if (this == that) {
            return true;
        }
        if (that == null) {
            return false;
        }
        if (getClass() != that.getClass()) {
            return false;
        }
        DzmHisPatientCredit other = (DzmHisPatientCredit) that;
        return (this.getId() == null ? other.getId() == null : this.getId().equals(other.getId()))
            && (this.getHospitalId() == null ? other.getHospitalId() == null : this.getHospitalId().equals(other.getHospitalId()))
            && (this.getPatientId() == null ? other.getPatientId() == null : this.getPatientId().equals(other.getPatientId()))
            && (this.getDoctorId() == null ? other.getDoctorId() == null : this.getDoctorId().equals(other.getDoctorId()))
            && (this.getQaId() == null ? other.getQaId() == null : this.getQaId().equals(other.getQaId()))
            && (this.getStatus() == null ? other.getStatus() == null : this.getStatus().equals(other.getStatus()))
            && (this.getQaId2() == null ? other.getQaId2() == null : this.getQaId2().equals(other.getQaId2()))
            && (this.getAddtime() == null ? other.getAddtime() == null : this.getAddtime().equals(other.getAddtime()))
            && (this.getUptime() == null ? other.getUptime() == null : this.getUptime().equals(other.getUptime()));
    }

    @Override
    public int hashCode() {
        final int prime = 31;
        int result = 1;
        result = prime * result + ((getId() == null) ? 0 : getId().hashCode());
        result = prime * result + ((getHospitalId() == null) ? 0 : getHospitalId().hashCode());
        result = prime * result + ((getPatientId() == null) ? 0 : getPatientId().hashCode());
        result = prime * result + ((getDoctorId() == null) ? 0 : getDoctorId().hashCode());
        result = prime * result + ((getQaId() == null) ? 0 : getQaId().hashCode());
        result = prime * result + ((getStatus() == null) ? 0 : getStatus().hashCode());
        result = prime * result + ((getQaId2() == null) ? 0 : getQaId2().hashCode());
        result = prime * result + ((getAddtime() == null) ? 0 : getAddtime().hashCode());
        result = prime * result + ((getUptime() == null) ? 0 : getUptime().hashCode());
        return result;
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(getClass().getSimpleName());
        sb.append(" [");
        sb.append("Hash = ").append(hashCode());
        sb.append(", id=").append(id);
        sb.append(", hospitalId=").append(hospitalId);
        sb.append(", patientId=").append(patientId);
        sb.append(", doctorId=").append(doctorId);
        sb.append(", qaId=").append(qaId);
        sb.append(", status=").append(status);
        sb.append(", qaId2=").append(qaId2);
        sb.append(", addtime=").append(addtime);
        sb.append(", uptime=").append(uptime);
        sb.append(", serialVersionUID=").append(serialVersionUID);
        sb.append("]");
        return sb.toString();
    }
}